package com.wteam.dragon.shop.pojo.bean;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.gitee.sunchenbin.mybatis.actable.annotation.*;
import com.gitee.sunchenbin.mybatis.actable.constants.MySqlTypeConstant;
import com.wteam.dragon.system.basebean.bean.BaseBean;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotNull;
import java.util.Date;

/**
 * @Author 陈晓辉
 * @Date 2021/3/24 15:25
 */
@Data
@Table
@TableName
@EqualsAndHashCode(callSuper = true)
public class FlashPromotionSession extends BaseBean {
    @IsKey
    @IsNotNull
    @IsAutoIncrement
    @TableId(type = IdType.AUTO)
    @ColumnType(MySqlTypeConstant.BIGINT)
    @Column(comment = "自增id")
    private Long id;

    @Column(comment = "场次名称")
    @ColumnType(MySqlTypeConstant.VARCHAR)
    private String name;

    @NotNull
    @Column(comment = "每日开始时间")
    @ColumnType(MySqlTypeConstant.TIMESTAMP)
    private Date startTime;

    @NotNull
    @Column(comment = "每日结束时间")
    @ColumnType(MySqlTypeConstant.TIMESTAMP)
    private Date endTime;

    @NotNull
    @Column(comment = "启用状态(0 不启用 1 启用))")
    @ColumnType(MySqlTypeConstant.TINYINT)
    @DefaultValue("0")
    private Integer status;
}
